package com.example.myanimator.evaluator;

import android.content.Context;
import android.graphics.Point;
import android.util.AttributeSet;
import android.widget.ImageView;

import androidx.appcompat.widget.AppCompatImageView;

/**
 * @author tgw
 * @date 2021/3/18
 * @describe
 */
public class FallingImageView extends AppCompatImageView {

    public FallingImageView(Context context) {
        super(context);
    }

    public FallingImageView(Context context, AttributeSet attrs) {
        super(context, attrs);
    }

    public FallingImageView(Context context, AttributeSet attrs, int defStyleAttr) {
        super(context, attrs, defStyleAttr);
    }


    public void setFallingPos(Point point){
        layout(point.x,point.y,point.x+getWidth(),point.y+getHeight());
    }
}
